package com.beeantec.jnrerc.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 
 * </p>
 *
 * @author anthony
 * @since 2021-12-16
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("news")
public class News extends Model<News> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    private String title;

    private String summary;

    private String pic;

    private String content;

    private String type;

    private Integer status;

    private String author;

    @TableField("createTime")
    private Date createTime;


    public static final String ID = "id";

    public static final String TITLE = "title";

    public static final String SUMMARY = "summary";

    public static final String PIC = "pic";

    public static final String CONTENT = "content";

    public static final String TYPE = "type";

    public static final String STATUS = "status";

    public static final String AUTHOR = "author";

    public static final String CREATETIME = "createTime";

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}
